package com.xneure.code.commport;

import com.xneure.code.event.Event;
import jssc.SerialPortEvent;

public class PortEvent extends SerialPortEvent implements Event{
	private CommPort source;
	private byte[] target;

	PortEvent(CommPort source,SerialPortEvent spe,byte[] data){
		super(spe.getPortName(),spe.getEventType(),spe.getEventValue());
		this.target = data;
		this.source = source;
	}

	public CommPort getSource(){
		return source;
	}

	public byte[] getTarget(){
		return target;
	}
}
